﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data.Common;

namespace Inovout.Gis.Data
{
    public class GisTransaction : DbTransaction
    {
        private readonly DbTransaction _transaction;
        private readonly DbConnection _connection;

        internal DbTransaction Transaction
        {
            get { return _transaction; }
        }

        public GisTransaction(DbConnection connection, DbTransaction transaction)
		{
			_connection = connection;
			_transaction = transaction;
		}

        public override void Commit()
        {
            Transaction.Commit();
        }

        protected override DbConnection DbConnection
        {
            get { return _connection; }
        }

        public override System.Data.IsolationLevel IsolationLevel
        {
            get { return Transaction.IsolationLevel; }
        }

        public override void Rollback()
        {
            Transaction.Rollback();
        }
    }
}
